﻿using System.Collections.Generic;

namespace CoreEx.Common.Extensions
{
    /// <summary>
    /// Represents a list of nouns in their plural and singular form.
    /// </summary>
    public interface IPluralRules : IEnumerable<PluralRule>
    {
        /// <summary>
        /// Adds a new <see cref="PluralRule"/> to the list.
        /// </summary>
        /// <param name="pluralRule">The <see cref="PluralRule"/> to add.</param>
        void Add(PluralRule pluralRule);
        
        /// <summary>
        /// Returns a list of nouns indexed by its plural form.
        /// </summary>
        /// <returns><see cref="IDictionary{TKey,TValue}"/></returns>
        IDictionary<string, string> AsPluralDictionary();

        /// <summary>
        /// Returns a list of nouns indexed by its singular form.
        /// </summary>
        /// <returns><see cref="IDictionary{TKey,TValue}"/></returns>
        IDictionary<string, string> AsSingularDictionary();
    }
}
